package controllers

import (
	"CRMSystem/models"
)

func GetSessionString(session interface{}) string {
	if d, ok := session.(string); ok {
		return d
	}
	return ""
}

func GetSessionInt(session interface{}) int {
	if d, ok := session.(int); ok {
		return d
	}
	return -999
}

func GetSessionContact(session interface{}) (models.Contacts, bool) {
	if d, ok := session.(models.Contacts); ok {
		return d, true
	}
	return models.Contacts{}, false
}
